import Cookies from "js-cookie";
class UseCookies {
  /*
   * 设置cookies
   * */
  get(key) {
    return Cookies.get(key);
  }
  /*
   * 设置Cookies
   * */
  set(key, value, expiresTime) {
    let seconds = expiresTime;
    let expires = new Date(new Date() * 1 + seconds * 1000);
    return Cookies.set(key, value, { expires: expires });
  }
  /*
   * 移除Cookies
   * */
  remove(key) {
    return Cookies.remove(key);
  }
}
const useCookies = new UseCookies();
export default useCookies;
